const axios = require("axios");
const { setEngine } = require("./engine");
const feishu = require("./feishu");
const bark = require("./bark");

setEngine(function request(url, params) {
  return axios(url, params);
});

/**
 * config feishu
 */
// feishu.add(
//   "build",
//   "https://open.feishu.cn/open-apis/bot/v2/hook/fd5ceeac-feec-40f5-acdc-aea8dbc68356"
// );
feishu.add(
  "weather",
  "https://open.feishu.cn/open-apis/bot/v2/hook/530ea8b8-3705-4bd9-9bc9-2126a7b0d5b8"
);
feishu.add(
  "waimai",
  "https://open.feishu.cn/open-apis/bot/v2/hook/c0ed460f-03cb-4ad0-9c40-4c87994229ae"
);
feishu.add(
  "juejin",
  "https://open.feishu.cn/open-apis/bot/v2/hook/1698d2b4-768f-4797-82c9-8def692ddc4c"
);
feishu.add('build', {
  appId: 'cli_a37b17bbdef8900e',
  appSecret: 'jzCjAXEE4eIaTCHv56KfFhH2nFiFBneh',
  // pushUrl: "https://open.feishu.cn/open-apis/bot/v2/hook/fd5ceeac-feec-40f5-acdc-aea8dbc68356"
})
feishu.add("chat", {
  appId: "cli_a366f8773c7a100b",
  appSecret: "cdxEFdRL5hEPMqJBmBpSwctjysGY1vGv",
  pushUrl:
    "https://open.feishu.cn/open-apis/bot/v2/hook/fd5ceeac-feec-40f5-acdc-aea8dbc68356",
});

/**
 * config bark
 */
bark.add("bibidu", "2t4AZUoXXn9rqWirT54kQD");

module.exports = {
  feishu,
  bark,
};
